package com.ssm.service;

import com.ssm.dao.UserMapper;
import com.ssm.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

public class UserServiceImpl implements UserService {

    private UserMapper mapper;

    public void setMapper(UserMapper mapper) {
        this.mapper = mapper;
    }

    @Override
    public List<User> findAll() {
        return mapper.findAll();
    }

    @Override
    public User findById(Integer id) {
        return mapper.findById(id);
    }
}
